package com.example.gsnd21study.mapper;

import com.example.gsnd21study.entity.Student;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import javax.websocket.server.PathParam;
import java.util.List;
@Mapper

public interface StudentMapper {
    //根据id查询一个人student 对象
    Student selectById(Long sno);
    //条件查询
    List<Student> selectByCondition (@Param("name") String name, @Param("age") Integer age,@Param("gender") String gender);
    //新增
    void insert(Student student);
    //修改
    void update(Student student);
    //删除单个
    void deleteById(Long sno);
    //批量删除
    void deleteBatch(@Param("snos") List<Long> snos);
}
